package com.ethan.minimalist.mvp.contract

import com.cxz.kotlin.baselibs.mvp.IModel
import com.cxz.kotlin.baselibs.mvp.IPresenter
import com.cxz.kotlin.baselibs.mvp.IView
import com.ethan.minimalist.bean.HttpResult
import com.ethan.minimalist.bean.UserBean
import io.reactivex.Observable

/**
 * @ClassName:      ILoginContract
 * @Description:
 * @Author:         ethanWu
 * @CreateDate:     2020/3/17 10:53
 */
interface IUpdateUserContract {
    interface View : IView {
        fun updateUserSuc()
        fun logoutSuccess()
    }

    interface Presenter : IPresenter<View> {
        fun update(username: String, password: String)
        fun logout()
    }

    interface Model : IModel {
        fun update(username: String, password: String): Observable<HttpResult<UserBean>>
        fun logout(): Observable<HttpResult<Any>>
    }
}